Skip to main content

link

Type

keyword

Summary

Used with the textStyle property to make a run of text in a field behave like a single word when clicked.

Syntax

link

Description

Use the link keyword to create clickable text.

Text with its textStyle set to "link" is treated specially by the clickText, clickChunk, mouseText, and mouseChunk functions: a style run of grouped text is treated as a single word. This makes grouped text handy to use for hypertext or "clickable text" features.

note

Each continuous run of "link"-styled text is considered a single text group, even if you selected part of the text and set its textStyle to "link", and set the textStyle of the other part later. It is not possible for two separate text groups to exist if there are no characters between them.

To show which text in a field is grouped, it is underlined and displayed in the color specified by the linkColor property. Use the hide groups command to hide the underline.

Examples

set the textStyle of the foundChunk to link

keyword: field, word, characters

message: linkClicked

property: textStyle, linkHiliteColor, selected, linkColor, linkText, linkVisitedColor

command: show groups, hide groups

function: clickChunk, mouseChunk, clickText, mouseText

glossary: property, keyword, grouped text, command, hypertext, function

Compatibility and Support

Introduced

LiveCode 1.0

OS

mac

windows

linux

ios

android

Platforms

desktop

server

mobile

Thank you for your feedback!

Was this page helpful?